package com.zpy.SmartChargeStation.iotdb.utils;

import com.zpy.SmartChargeStation.iotdb.service.impl.IoTDBServiceImpl;
import jakarta.annotation.Resource;
import org.apache.iotdb.isession.pool.SessionDataSetWrapper;

import java.util.List;

/**
 * description: iotdb Session工具类
 */

public class IoTDBUtils {

    @Resource
    private IoTDBServiceImpl service;



    /**
     * description: 根据自定义sql语句查询数据
     */
    SessionDataSetWrapper executeQueryStatement(String sql) {

        return service.executeQueryStatement(sql);
    }


    /**
     * description: 根据时间区间(左比右开)查询数据
     */
    SessionDataSetWrapper executeRawDataQuery(List<String> path, long startTime, long endTime, long timeOut) {

       return service.executeRawDataQuery(path,startTime,endTime,timeOut);
    }
}
